From: Richard M. Stallman Date: Fri, 5 Mar 1993 23:56:43 +0000 (+0000) Subject: (current_column, Fmove_to_column, compute_motion): X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1^2~5^2~97043 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:/?a=commitdiff_plain;h=dea4d2e67124b9ef943d54b265271e3af22e1e82;p=emacs.git (current_column, Fmove_to_column, compute_motion): Expect display table elts to be vectors. --- diff --git a/src/indent.c b/src/indent.c index f991c56ef25..9258dcc74db 100644 --- a/src/indent.c +++ b/src/indent.c @@ -137,7 +137,7 @@ current_column () c = *--ptr; if (c >= 040 && c < 0177 - && (dp == 0 || XTYPE (DISP_CHAR_ROPE (dp, c)) != Lisp_String)) + && (dp == 0 || XTYPE (DISP_CHAR_VECTOR (dp, c)) != Lisp_Vector)) { col++; } @@ -154,8 +154,8 @@ current_column () col = 0; tab_seen = 1; } - else if (dp != 0 && XTYPE (DISP_CHAR_ROPE (dp, c)) == Lisp_String) - col += XSTRING (DISP_CHAR_ROPE (dp, c))->size / sizeof (GLYPH); + else if (dp != 0 && XTYPE (DISP_CHAR_VECTOR (dp, c)) == Lisp_Vector) + col += XVECTOR (DISP_CHAR_VECTOR (dp, c))->size; else col += (ctl_arrow && c < 0200) ? 2 : 4; } @@ -329,8 +329,8 @@ and if COLUMN is in the middle of a tab character, change it to spaces.") col += tab_width; col = col / tab_width * tab_width; } - else if (dp != 0 && XTYPE (DISP_CHAR_ROPE (dp, c)) == Lisp_String) - col += XSTRING (DISP_CHAR_ROPE (dp, c))->size / sizeof (GLYPH); + else if (dp != 0 && XTYPE (DISP_CHAR_VECTOR (dp, c)) == Lisp_Vector) + col += XVECTOR (DISP_CHAR_VECTOR (dp, c))->size; else if (ctl_arrow && (c < 040 || c == 0177)) col++; else if (c < 040 || c >= 0177) @@ -434,8 +434,8 @@ compute_motion (from, fromvpos, fromhpos, to, tovpos, tohpos, width, hscroll, ta : !NILP (current_buffer->selective_display) ? -1 : 0; int prev_vpos, prev_hpos; int selective_rlen - = (selective && dp && XTYPE (DISP_INVIS_ROPE (dp)) == Lisp_String - ? XSTRING (DISP_INVIS_ROPE (dp))->size / sizeof (GLYPH) : 0); + = (selective && dp && XTYPE (DISP_INVIS_VECTOR (dp)) == Lisp_Vector + ? XVECTOR (DISP_INVIS_VECTOR (dp))->size : 0); if (tab_width <= 0 || tab_width > 20) tab_width = 8; for (pos = from; pos < to; pos++) @@ -450,7 +450,7 @@ compute_motion (from, fromvpos, fromhpos, to, tovpos, tohpos, width, hscroll, ta c = FETCH_CHAR (pos); if (c >= 040 && c < 0177 - && (dp == 0 || XTYPE (DISP_CHAR_ROPE (dp, c)) != Lisp_String)) + && (dp == 0 || XTYPE (DISP_CHAR_VECTOR (dp, c)) != Lisp_Vector)) hpos++; else if (c == '\t') { @@ -506,8 +506,8 @@ compute_motion (from, fromvpos, fromhpos, to, tovpos, tohpos, width, hscroll, ta hpos = width; } } - else if (dp != 0 && XTYPE (DISP_CHAR_ROPE (dp, c)) == Lisp_String) - hpos += XSTRING (DISP_CHAR_ROPE (dp, c))->size / sizeof (GLYPH); + else if (dp != 0 && XTYPE (DISP_CHAR_VECTOR (dp, c)) == Lisp_Vector) + hpos += XVECTOR (DISP_CHAR_VECTOR (dp, c))->size; else hpos += (ctl_arrow && c < 0200) ? 2 : 4;